<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <style>
        * {
            padding: 0;
            margin: 0;
        }
        #box {
            width: 100%;
            margin:  100px auto;
            /* perspective: 1200px; */
            /* transform-style: preserve-3d; */
        }
        .aaa, .bbb, .ccc {
            width: 150px;
            height: 150px;
            background-color: #ff5700;
            transform:  perspective(700px) rotateX(0);
            transition: 3s all ease;
            margin-left: 100px;
            float:left;
            font-size: 30px;
            color: #fff;
            line-height: 150px;
            text-align: center;
        }
        .aaa:active {
            transform: perspective(700px) rotateX(360deg);
        }
        .bbb:active {
            transform: perspective(700px) rotateY(360deg);
        }
        .ccc:active {
            transform: perspective(700px) rotateZ(360deg);
        }
    </style>
</head>
<body>
    <div id="box">
        <div class="aaa">1</div>
        <div class="bbb">2</div>
        <div class="ccc">3</div>
    </div>
    <!-- <div id="box2"></div> -->
</body>
</html>